home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
EnigmA Amiga Run 1996 March
/
EnigmA AMIGA RUN 05 (1996)(G.R. Edizioni)(IT)[!][issue 1996-03][Skylink CD IV].iso
/
earcd
/
comm2
/
pong11.lha
/
pong.readme
< prev
Wrap
Text File
|
1995-10-11
|
3KB
|
69 lines
Short: network host monitor
Type: comm/net
Uploader: mlelstv@serpens.rhein.de
Author: mlelstv@serpens.rhein.de
pong is a utility that monitors the presence of hosts on the net
using the ICMP ECHO protocol (aka 'ping').
History:
After we got private access to the internet we had to fight many
problems with unstable software and modems or ISDN links suddenly
dropping connections.
I wrote a shell script that pinged a couple of strategic hosts and
routers. When a host answered a ping it was considered 'up', otherwise
'down' and a change in state was reported with the say command.
This way I was alerted when there was a problem even when I was busy
with other things.
This script was started every few minutes by DCron (from Matt Dillon).
This had the disadvantage that every few minutes a program used the
hard disk, trashed SnoopDos output and slowed other programs down.
pong does basically the same as the monitoring script. It takes a
list of hosts from a configuration file, tries to ping these and
report state changes on standard output. The messages are also read
from the configuration file. You can redirect the messages to SPEAK:
for audible reports or pipe the output to a shell so that any command
can be executed when a host becomes reachable or unreachable.
pong runs in infinite loop. You have to abort it with ctrl-c or
the BREAK command.
Usage:
pong CONFIG/A,CHECK/K/N,RETRY/K/N,PRESET/S,TO/K:
CONFIG/A the name of the configuration file
CHECK/K/N n recheck a host every n seconds that was found alive
the default is 300 seconds
RETRY/K/N n if a host does not reply in n seconds it is considered down
the default is 30 seconds
PRESET/S do not report the initial state of each host
TO/K the name of a redirection file. Only status messages are
sent to that file. A shell redirection would also send
possible error messages.
The config file is a sequence of lines that are also parsed with ReadArgs.
The template is:
HOST/A,UP/K/A,DOWN/K/A,CHECK/K/N,RETRY/K/N
HOST/A is the name of IP number of the host.
UP/K/A is the string to be printed when the host becomes alive
DOWN/K/A is the string to be printed when the host becomes unreachable
CHECK/K/N and
RETRY/K/N are optional CHECK and RETRY settings for this host that override
the command line parameters
pong is written for the AS225 TCP/IP protocol stack. It should also work
with the socket.library emulation from Henning Schmiedehausen and AmiTCP.
Changes:
1.1 considers a host down if a ping fails twice in a row. This
avoids messages if a packet is lost on transit.
Michael van Elst